home *** CD-ROM | disk | FTP | other *** search
/ Turnbull China Bikeride / Turnbull China Bikeride - Disc 1.iso / ARGONET / PD / PROGRAMMING / DESKLIBC / SOURCES.ZIP / DeskLib / !DLSources / Libraries / PDriver / DLL / MakeDLL < prev    next >
Text File  |  1995-07-08  |  4KB  |  149 lines

  1.  
  2. ObjectFiles    =        \
  3.             o.AbortJob    \
  4.             o.CancelJob    \
  5.             o.CancelJobW    \
  6.             o.CheckFeatu    \
  7.             o.CurrentJob    \
  8.             o.DrawPage    \
  9.             o.EndJob    \
  10.             o.EnumerateJ    \
  11.             o.GetRectang    \
  12.             o.GiveRectan    \
  13.             o.Info    \
  14.             o.InsertIllu    \
  15.             o.PageSize    \
  16.             o.PrintrName    \
  17.             o.ScreenDump    \
  18.             o.SelectIllu    \
  19.             o.SelectJob    \
  20.  
  21.  
  22. LibName        =    PDriver
  23.  
  24.  
  25.  
  26. # Template makefile to make Straylight Dynamic Link 
  27. # Library from a DeskLib sublibrary's .o files
  28. #
  29. # The DLL is made in the directory 
  30. # '<DeskLib$Dir>.!DLLs.Freeware_1.DeskLib.'
  31. # and has the same name as the DeskLib sublibrary.
  32. #
  33. # Julian Smith 17 Apr 1995.
  34.  
  35. # The macro $(ObjectFiles) should be set at the 
  36. # start of this file, to be a space-separated
  37. # list of object files.
  38. # This is done by 'Makatic'.
  39.  
  40. # The macro $(LibName) should also be set at the 
  41. # start of this file, to be the name of the 
  42. # DeskLib sublibrary.
  43. # This is done by 'Makatic'.
  44.  
  45. # Note that this makefile doesn't use cc at all
  46. # - it merely links existing .o files.
  47.  
  48. # Linker flags, These can be anything. 
  49. # All flags required by Straylight (eg Link -rmf) 
  50. # are included in the $(LINK) macro.
  51. #
  52. LinkFlags    =    $(LinkExtra)
  53.  
  54.  
  55. # Macros for commands, including the Straylight
  56. # tool 'cdll'. Note that DRLink doesn't seem to
  57. # work with the SDLS.
  58. #
  59. LINK        =    Link -rmf
  60. CDLL        =    cdll
  61.  
  62.  
  63. # Filename of the thing we need to make: - the main
  64. # dynamically-linked library, which will go in the 
  65. # !DLL application.
  66. # NB The leafname of $(DLL_Lib) file (after copying into the !DLL
  67. # application) should be the same as the 'name' field in the
  68. # $(DLL_Def) file. In this case, this is $(LibName).
  69. DLL_Lib        =    <DeskLib$Dir>.!DLLs.Freeware_1.DeskLib.$(LibName)
  70.  
  71.  
  72. # Filenames of intermediate files needed to make $(DLL_Lib) and $(DLL_Stubs).
  73. #
  74. DLL_Header    =    Header
  75. DLL_Def        =    ^.DLLDef
  76. DLL_Stubs    =    Stubs
  77.  
  78.  
  79.  
  80. # -------------------------------------------------------
  81. # Everything below here should probably not be changed...
  82. # -------------------------------------------------------
  83.  
  84.  
  85. # Extra libs, written by Straylight, which always need to be linked into a DLL
  86. #
  87. SDLS_ExtraObjects=                    \
  88.             C:DLLLib.o.DLLLib        \
  89.             C:DLLLib.o.dstubs        \
  90.  
  91.  
  92. # Extra DeskLib libraries which need to be linked into the final DLL.
  93. # The DLL DeskLib library is included here because some DeskLib DLLs may
  94. # refer to other DeskLib DLLs.
  95. # Note that DeskLib:o.DLL contains all the DLL.o.* files except for 
  96. # the sublibraries for which there is a DLL - just the DLL Stubs file
  97. # is included for these.
  98. #
  99. DeskLib_ExtraObjects=                \
  100.             DeskLib:o.DLLDLL    \
  101.  
  102.  
  103.  
  104.  
  105. #Here's what we want to make...
  106.  
  107. All:    $(DLL_Lib)
  108.  
  109. $(DLL_Lib):    $(DeskLib_ExtraObjects) $(SDLS_ExtraObjects) $(DLL_Header) $(ObjectFiles)
  110.     $(LINK) $(LinkFlags) -o $@ $(ObjectFiles) $(DeskLib_ExtraObjects) $(SDLS_ExtraObjects) $(DLL_Header)
  111.  
  112.  
  113.  
  114. # Here's how to make the things which are needed in the above rules
  115.  
  116. $(DLL_Def):    
  117.     | Error: No DLL definition file exists.
  118.     |        You should run th MkStubsOs makefile
  119.     |        and then alter the template Def
  120.     |        file by hand.
  121.  
  122. $(DLL_Header):    $(DLL_Def)
  123.     $(CDLL) -def $(DLL_Def) -hdr $(DLL_Header)
  124.  
  125.  
  126. # Rule for compiling C source code for a Straylight dynamically-linked library.
  127. # Actually, we don't call cc - we complain and tell the user to run the 
  128. # MkStubsOs makefile.
  129.  
  130. VPATH = @.^
  131.  
  132. .SUFFIXES:    .o .c .s
  133. .c.o:
  134.     | $@ needs recompiling. This should be done by
  135.     | running the MkStubsOs or MkOs makefile before running
  136.     | this makefile.
  137.     |
  138.  
  139. .s.o:
  140.     | $@ needs assembling. This should be done by
  141.     | running the MkStubsOs or MkOs makefile before running
  142.     | this makefile.
  143.     |
  144.  
  145.  
  146.  
  147. # Dynamic dependencies:
  148.